﻿$def with (name)
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">

<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>古体诗创作与分享</title>
    <script src="" type="text/javascript"></script>
    <script language="javascript"> 
    function pwenter()
    {
        var event=window.event?window.event:event;
        if(event.keyCode==13 && event.srcElement.name=="pwd")
        	window.document.loginform.submitusr.click();   
    }
    function check_val()
    {
        if (document.loginform.usrname.value=="")
        {
            alert("请输入用户名!");
            document.loginform.usrname.focus();
            return false;
        }
        if (document.loginform.pwd.value =="")
        {
            alert("请输入密码!");
            document.loginform.pwd.focus();
            return false; 
        }   
        document.loginform.submit();
    }
    </script>
    <noscript>Please enabled your broswer's javascript support!<br>请启用你的浏览器的javascript支持!</noscript>
</head>

<body>
<div id="body">

<div id="loginDiv">
    <form method="post" action="confirm"   name="loginform">
    <table>
        <tr class="hellofont">欢迎来到古诗创作与分享平台</tr>
	<tr>
            <td>
            用户名：<input type="text" id="usrname" name="usrname" class="button"><br /><br />
            密&nbsp;&nbsp;&nbsp;&nbsp;码：<input type="password" id="pwd" name ="pwd" class="button" onKeydown="pwenter()"><br /><br />
            </td>
        </tr>
        <tr>
            <td><input type="button" name="submitusr" value="用户登陆" class="button" onClick="javascript:check_val()"></td>
            <td><input type="button" name="submitguest" value="游客访问" class="button" onClick="submit()"></td>
	    <td><a href="/newreg">新用户注册</a></td>
        </tr>
    </table></form>
    $name       
</div>

</div>
</body>
</html>

